package main

import (
	"fmt"
	"regexp"
)

func main() {
	buf := "3.14 567 a7c 1.23 7.  .3 84.99 fdfadgh[] 236.666"

	//reg := regexp.MustCompile(`\d{2}\.\d*`)
	//reg := regexp.MustCompile(`\d*\.\d*`)
	//reg := regexp.MustCompile(`\d{0,2}\.\d*`)
	//reg := regexp.MustCompile(`\d+\.\d*`) // 1 n
	reg := regexp.MustCompile(`\d?\.\d*`) // 0 n
	if reg == nil {
		fmt.Println("err = ", reg)
		return
	}

	allString := reg.FindAllString(buf, -1)
	fmt.Println(allString)
}
